package pacs_server

import (
	"github.com/sirupsen/logrus"
	"time"
)

type PacsManager struct {
	autoSync         bool
	autoSyncDuration time.Duration
	autoSyncStopSign chan int
	tableServerList  string
	logger           *logrus.Entry
}

type PacsServer struct {
	ServerName string `gorose:"server_name" json:"server_name,omitempty"`
	ServerType string `gorose:"server_type" json:"server_type,omitempty"`
	ServerHost string `gorose:"server_host" json:"server_host,omitempty"`
	ServerAETs string `gorose:"server_aets" json:"server_aets,omitempty"`
	TableTitle string `gorose:"table_title" json:"table_title,omitempty"`
	CacheRoot  string `gorose:"cache_root" json:"cache_root"`
	ShowHidden bool
	OnlyHidden bool
	ShowDelete bool
	chanWorker chan int
	ID         string
	logger     *logrus.Entry
}

type SyncWorker struct {
	Id              int
	flagBusy        bool
	chanFree        chan int
	chanFeed        chan FeedInfo
	chanStop        chan int
	pacsServer      *PacsServer
	Stat            ImportDetails
	enableQuickMode bool
	logger          *logrus.Entry
}

type ImportDetails struct {
	CountStudies  int
	CountSeries   int
	CountInstance int
	ImportStudies []string
}
